home *** CD-ROM | disk | FTP | other *** search
/ Team Palmtops 7 / Palmtops_numero07.iso / WinCE / SDKWindowsCE / HandHeldPCPro30 / sdk.exe / Jupiter SDK / data1.cab / MFC_Samples / chatter / chatsock.cpp < prev    next >
Encoding:
C/C++ Source or Header  |  1999-02-19  |  918 b   |  38 lines

  1. // chatsock.cpp : implementation file
  2. //
  3. // This is a part of the Microsoft Foundation Classes C++ library.
  4. // Copyright (C) 1999 Microsoft Corporation
  5. // All rights reserved.
  6. //
  7. // This source code is only intended as a supplement to the
  8. // Microsoft Foundation Classes Reference and related
  9. // electronic documentation provided with the library.
  10. // See these sources for detailed information regarding the
  11. // Microsoft Foundation Classes product.
  12.  
  13. #include "stdafx.h"
  14. #include "chatter.h"
  15.  
  16. #include "chatsock.h"
  17. #include "chatdoc.h"
  18.  
  19. #ifdef _DEBUG
  20. #undef THIS_FILE
  21. static char BASED_CODE THIS_FILE[] = __FILE__;
  22. #endif
  23.  
  24. IMPLEMENT_DYNAMIC(CChatSocket, CSocket)
  25.  
  26. CChatSocket::CChatSocket(CChatDoc* pDoc, PURPOSE_E iPurpose) :
  27.     CCeSocket(iPurpose)
  28. {
  29.     m_pDoc = pDoc;
  30. }
  31.  
  32. void CChatSocket::OnReceive(int nErrorCode)
  33. {
  34.     CSocket::OnReceive(nErrorCode);
  35.  
  36.     m_pDoc->ProcessPendingRead();
  37. }
  38.